www.gusucode.com > 中国货源网导航程序源码 1 > 中国货源网导航程序源码 1.0/8月11日备份/create_html.asp
<!--#include file="mdb.asp"--> <% if session("adminlogin")<>sessionvar then Response.Write("<script language=javascript>alert('你尚未登录,或者超时了!请重新登录');this.location.href='admin/index.asp';</script>") Response.End End if set rs=server.createobject("adodb.recordset") rs.open "select * from title",conn,1,3 site=rs("site") siteurl=rs("siteurl") email=rs("email") Powered=rs("Powered") Copyright=rs("Copyright") xiaoyu_ku=rs("xiaoyu_ku") xiaoyu_baidu=rs("xiaoyu_baidu") xiaoyu_ads03=rs("xiaoyu_ads03") xiaoyu_ads07=rs("xiaoyu_ads07") xiaoyu_ads08=rs("xiaoyu_ads08") xiaoyu_ads09=rs("xiaoyu_ads09") xiaoyu_ads10=rs("xiaoyu_ads10") rs.close classid=request("classid") rs.open "select * from feilei where classid="&classid,conn,1,3 classname=rs("classname") topclass=rs("topclass") rs.close dim wstr,fso,fw set fr=server.createobject("adodb.recordset") fr.open "select * from template where id=1",conn,1,3 wstr=fr("template") fr.close set fr=nothing dim rstr,xunxu xunxu="→<a class=word_White href='xiaoyu_url0"&classid&".htm'>" & classname & "</a>" while topclass<>0 rs.open "select * from feilei where classid="&topclass,conn,1,3 if not rs.eof then xunxu="→<a class=word_White href='xiaoyu_url0" & rs("classid") & ".htm'>" & rs("classname") & "</a>" & xunxu topclass=rs("topclass") end if rs.close wend wstr=replace(wstr,"<{{sc1}}>",xunxu) tj="" Set Count=Server.CreateObject("Adodb.Recordset") Sql="select * from detail where verity=1 and classid="&classid&"" Count.open Sql,conn,1,1 tj=tj&"共有["&Count.RecordCount&"]个网站" Count.close Set Count = Nothing wstr=replace(wstr,"<{{tj}}>",tj) rs.open "select * from feilei where topclass="&classid,conn,1,3 jishu=1 if rs.eof then rstr=rstr&"" end if while not rs.eof if jishu=1 or jishu mod 8 = 1 then rstr=rstr & "<tr><td width='150' height='20' align=center><a href='xiaoyu_url0"&rs("classid")&".htm'>["&rs("classname")&"]</a></td>" else rstr=rstr & "<td width='150' height='20' align=center><a href='xiaoyu_url0"&rs("classid")&".htm'>["&rs("classname")&"]</a></td>" end if if jishu mod 8 =0 then rstr=rstr & "</tr>" jishu=jishu+1 rs.movenext wend jishu=jishu-1 if jishu mod 8 <> 0 then for i= 1 to 8-(jishu mod 7) rstr=rstr & "<td width='100'> </td>" if i = 8-(jishu mod 8) then rstr=rstr & "</tr>" next end if rs.close wstr=replace(wstr,"<{{sc2}}>",rstr) rstr=empay Copyright=Copyright&Powered rs.open "select * from detail where verity=1 and classid="&classid&" order by yl_yesterin desc,id",conn,1,3 jishu=1 noooo=1 while not rs.eof if jishu=1 or jishu mod 4 = 1 then noooo=noooo+1 if noooo mod 2=1 then bgcolor="#FFFFFF" else bgcolor="#F7F7F7" end if if rs("topid")>0 then rstr=rstr & "<tr bgColor="&bgcolor&"><td width='25%' height='25'> <a class=word href='../showurl.asp?id="&rs("id")&"' title=昨日来路:"&rs("yl_yesterin")&"|总来路:"&rs("yl_in")&"|总去路:"&rs("out")&" target='_blank'>" if rs("yl_yesterin")>4 then rstr=rstr & "<font color=#0000FF>" end if if rs("yl_yesterin")>9 then rstr=rstr & "</font><font color=#FF0000><b>" end if rstr=rstr & " "&rs("title")&" " if rs("yl_yesterin")>4 then rstr=rstr & "</b></font>" end if rstr=rstr & " <font color=#C60A00>荐</font></a> <a href='http://www.baidu.com/baidu?word="&rs("title")&"&tn=100-86com_pg' target='_blank'>☆</a></td>" else rstr=rstr & "<tr bgColor="&bgcolor&"><td width='25%' height='25'> <a class=word href='../showurl.asp?id="&rs("id")&"' title=昨日来路:"&rs("yl_yesterin")&"|总来路:"&rs("yl_in")&"|总去路:"&rs("out")&" target='_blank'>" if rs("yl_yesterin")>4 then rstr=rstr & "<font color=#0000FF>" end if if rs("yl_yesterin")>9 then rstr=rstr & "</font><font color=#FF0000><b>" end if rstr=rstr & " "&rs("title")&" " if rs("yl_yesterin")>4 then rstr=rstr & "</b></font>" end if rstr=rstr & "</a> <a href='http://www.baidu.com/baidu?word="&rs("title")&"&tn=100-86com_pg' target='_blank'>☆</a></td>" end if else if rs("topid")>0 then rstr=rstr & "<td width='25%' height='20'> <a class=word href='../showurl.asp?id="&rs("id")&"' title=昨日来路:"&rs("yl_yesterin")&"|总来路:"&rs("yl_in")&"|总去路:"&rs("out")&" target='_blank'>" if rs("yl_yesterin")>4 then rstr=rstr & "<font color=#0000FF>" end if if rs("yl_yesterin")>9 then rstr=rstr & "</font><font color=#FF0000><b>" end if rstr=rstr & " "&rs("title")&" " if rs("yl_yesterin")>4 then rstr=rstr & "</b></font>" end if rstr=rstr & " <font color=#C60A00>荐</font></a> <a href='http://www.baidu.com/baidu?word="&rs("title")&"&tn=100-86com_pg' target='_blank'>☆</a></td>" else rstr=rstr & "<td width='25%' height='20'> <a class=word href='../showurl.asp?id="&rs("id")&"' title=昨日来路:"&rs("yl_yesterin")&"|总来路:"&rs("yl_in")&"|总去路:"&rs("out")&" target='_blank'>" if rs("yl_yesterin")>4 then rstr=rstr & "<font color=#0000FF>" end if if rs("yl_yesterin")>9 then rstr=rstr & "</font><font color=#FF0000><b>" end if rstr=rstr & " "&rs("title")&" " if rs("yl_yesterin")>4 then rstr=rstr & "</b></font>" end if rstr=rstr & "</a> <a href='http://www.baidu.com/baidu?word="&rs("title")&"&tn=100-86com_pg' target='_blank'>☆</a></td>" end if end if if jishu mod 4 =0 then rstr=rstr & "</tr>" jishu=jishu+1 rs.movenext wend jishu=jishu-1 if jishu mod 4 <> 0 then for i= 1 to 4-(jishu mod 4) rstr=rstr & "<td width='25%'> </td>" if i = 4-(jishu mod 4) then rstr=rstr & "</tr>" next end if rs.close wstr=replace(wstr,"<{{sc3}}>",rstr) wstr=replace(wstr,"<{{classname}}>",classname) wstr=replace(wstr,"<{{site}}>",site) wstr=replace(wstr,"<{{siteurl}}>",siteurl) wstr=replace(wstr,"<{{email}}>",email) wstr=replace(wstr,"<{{Copyright}}>",Copyright) wstr=replace(wstr,"<{{creattime}}>",date()) wstr=replace(wstr,"<{{xiaoyu_ads03}}>",xiaoyu_ads03) wstr=replace(wstr,"<{{xiaoyu_ads07}}>",xiaoyu_ads07) wstr=replace(wstr,"<{{xiaoyu_ads08}}>",xiaoyu_ads08) wstr=replace(wstr,"<{{xiaoyu_ads09}}>",xiaoyu_ads09) wstr=replace(wstr,"<{{xiaoyu_ads10}}>",xiaoyu_ads10) wstr=replace(wstr,"<{{xiaoyu_ku}}>",xiaoyu_ku) wstr=replace(wstr,"<{{xiaoyu_baidu}}>",xiaoyu_baidu) Set fso=Server.CreateObject("Scripting.FileSystemObject") set fw=fso.createtextfile(server.mappath("html/xiaoyu_url0"&classid&".htm"),true) fw.writeline wstr fw.close set rs=nothing set fso=nothing response.write "ok" %>